]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
run-js-test: fix running in hi-dpi mode
authorOwen W. Taylor <otaylor@fishsoup.net>
Tue, 27 Oct 2015 19:51:13 +0000 (15:51 -0400)
committerOwen W. Taylor <otaylor@fishsoup.net>
Thu, 30 Jun 2016 18:17:19 +0000 (14:17 -0400)
src/run-js-test.c

index b90c0b6f6f41e6bd04f9969fc4519a602a969a23..bd76d9568057f4ad941d9a506b16ba8d84e94c7b 100644 (file)
@@ -59,6 +59,8 @@ main(int argc, char **argv)
   gsize len;
   int code;
 
+  gdk_set_allowed_backends("x11");
+
   gtk_init (&argc, &argv);
 
   clutter_x11_set_display (GDK_DISPLAY_XDISPLAY (gdk_display_get_default ()));
@@ -66,6 +68,9 @@ main(int argc, char **argv)
   if (clutter_init (&argc, &argv) != CLUTTER_INIT_SUCCESS)
     return 1;
 
+  g_object_set (clutter_settings_get_default (), "window-scaling-factor", 1, NULL);
+  gdk_x11_display_set_window_scale (gdk_display_get_default (), 1);
+
   context = g_option_context_new (NULL);
 
   /* pass unknown through to the JS script */